package com.gavin.ioc.service;

import com.gavin.ioc.model.Student;
import jakarta.annotation.Resource;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;

@Service
public class UserService {

//    @Qualifier("s2")
//    @Autowired
//    private Student s1;
    @Resource(name="s2")
    private Student s1;
    public void print(){
        System.out.println("do service");
        System.out.println(s1);
    }
}
